package com.miui.systemui.tools

import com.intellij.notification.Notification
import com.intellij.notification.NotificationType
import com.intellij.notification.Notifications
import com.intellij.notification.NotificationGroup
import javax.swing.Timer
import java.awt.event.ActionEvent
import java.awt.event.ActionListener
class MessageDialogUtils {

    companion object {

        fun createCustomNotification(content: String) {
            val notification = Notification(
                "figma2xml", // 通知组 ID（用于唯一标识通知）
                "auto replace", // 通知标题
                content, // 通知内容
                NotificationType.INFORMATION // 通知类型为信息
            )

            Notifications.Bus.notify(notification)
            Timer(1500, ActionListener { notification.expire() }).start()
        }
    }

}